package com.henry.lifegame;

import java.io.FileNotFoundException;

public class GameDemo {

    public static void main(String[] args) {
        try {
            PGM p = PGM.loadPGMFromFile("src/main/resources/LifeGame/16x16.pgm");
            if (p == null) return;
            GameOfLife inst = new GameOfLife(p.getHeight(), p.getWidth(), p.getData());

            for (int i = 0; i < 100; i++) {
                inst.next();
            }
        } catch (FileNotFoundException e) {
            System.out.println(e);
        }
    }
}
